package cn.itsource.basic.util;

import cn.hutool.http.HttpUtil;
import org.springframework.stereotype.Component;

import java.util.HashMap;
import java.util.Map;

@Component
public class SMSUtil {


    public static void  sendSMS(String phone,String code){

        Map<String, Object> param = new HashMap<>();
        param.put("Uid","怡米宝儿");
        param.put("Key","d41d8cd98f00b204e980");
        param.put("smsMob",phone);
        param.put("smsText","【验证码为:】"+code);
        String post = HttpUtil.post("http://utf8.api.smschinese.cn/", param);
        System.out.println(post);

    }


}
